#include "vectorfunctions.h"
#include <iostream>

int main()
{
	int mat[10][10];
	int prin[100], sec[100];
	int i, j, row, col;
	int rows1, rows2, cols1, cols2, aux;
	cout<<"Number of rows ";
	cin>>row;
	cout<<"Number of colons ";
	cin>>col;
	for (i=0; i<row; i++)
		for (j=0; j<col; j++){
			cout<<"m["<<i<<"]["<<j<<"]= ";
			cin>>mat[i][j];	
		}
	cout<<"Line 1 to interchange : ";
	cin>>rows1;
	cout<<"Line 2 to interchange : ";
	cin>>rows2;
	cout<<"Column 1 to interchange : ";
	cin>>cols1;
	cout<<"Column to interchange : ";
	cin>>cols2;

	for(j=0; j<col; j++){
		aux=mat[rows1][j];
		mat[rows1][j]=mat[rows2][j];
		mat[rows2][j]=aux;
	}
	for(i=0; i<row; i++){
		aux=mat[i][cols1];
		mat[i][cols1]=mat[i][cols2];
		mat[i][cols2]=aux;
	}
	for (i=0; i<row; i++){
		for (j=0; j<col; j++)
			cout<<mat[i][j]<<" ";
		cout<<endl;	
		}
	

	
return 0;
}
